<!doctype html>
<html>
<head>
<script src="http://res.wx.qq.com/open/js/jweixin-1.2.0.js"></script>  
<meta charset="UTF-8">
<meta content="width=device-width,initial-scale=1,maximum-scale=1,user-scalable=0," name="viewport">
<meta content="user-scalable=no" name="viewport">
<title>至富通钱包</title>
<script src="http://__JS__/jquery.js"></script>
<script src="http://__JS__/pageloader.js"></script>                                
<link href="http://__CSS__/my-style.css" rel="stylesheet" type="text/css">
<link rel="icon" href="http://__IMG__/favicon.ico">
</head>

<body>
<script type="text/javascript">
     function MemberTixian() { 
    $.ajax({ 
        type : "post", 
        url : "__URL__WithdrawController/MemberWithdraw", 
        data : $("#tixian").serialize(), 
        cache : false, 
        dataType : "json", 
        success : function(data) { 
        	  alert(data); 
        	//不好使改成用form了  location.href="__URL__ShowController/PersonalCenter";
        }, 
        error : function(data) { 
            alert("亲，当前提现用户过多，等下在试试吧！"); 
        } 
    }); 
} 

      </script>  

<!--提现弹窗-->
<div class="tixian1" id="tixian1"></div>
<div class="tixian2">
  <p class="tixian3">默认金额为全部可提现金额<span class="tixian4">关闭</span></p>
   <div class="hxhx" style="position:absolute; top:56px;"></div>
  <p class="tixian5">¥</p>
   <form action="__URL__PersonalCenterController/PersonalCenter" method="post">
    <input class="tixian6" id="tixian" type="number" name="withdrawMoney" value="{$allowMoney}" placeholder="输入提现金额" >
     <button class="tixian7" onclick="MemberTixian();">立即提现</button>
   </form>
</div>
<!--提现弹窗-->
<!--头像{$headimgurl}-->
<div id="grad1">
  <img src= "<?php echo $headimgurl;?>" width="170" class="grad1-img">
   <div class="grad1-wz">
    <p>{$nickname}</p>
     <p>ID: {$id}</p>
   </div>
 </div>
</div>
<!--按钮组-->
<div class="anz-bj">
 <div class="anz-block" id="yao1" onClick="hide()">
  <img src="http://__IMG__/qianbao2.png" width="100" class="anz-img">
  <p class="anz-wz">钱包</p>
 </div>
 <div class="anz-block" id="ti">
  <img src="http://__IMG__/tixian.png" width="100" class="anz-img">
  <p class="anz-wz">提现</p>
 </div>
 <div class="anz-block" id="yao3" onClick="showtx()">
  <img src="http://__IMG__/txjl.png" width="100" class="anz-img">
  <p class="anz-wz">提现明细</p>
 </div>
 <div class="anz-block" id="yao2" onClick="show()">
  <img src="http://__IMG__/hbjl.png" width="100" class="anz-img">
  <p class="anz-wz">红包记录</p>
 </div> 
</div>
 <div style=" background:#f4f5f6; width:100%; height:30px; float:left;">
 </div>
<!--下方的内容-->
<!--section1-->
<section id="nash1">
<div class="xfnr-bx">
 <strong class="xfnr-wz">钱包余额<span class="xfnr-wz3">{$money}</span></strong>
</div>
<div class="xfnr-bx">
 <strong class="xfnr-wz">可提现<span class="xfnr-wz3">{$allowMoney}</span></strong>
</div>
</section>
<!--section2-->
<section style="display:none;" id="nash2">

  {volist name="RedPackMsg" id="rl" }
  <div class="xfnr-bx">
   <div class="xfnr-wz">时间:<span class="xfnr-wz4">{$rl.create_time}</span></div>
   <div class="xfnr-wz">商家：<span class="xfnr-wz4">{$rl.store_name}</span></div>
   <div class="xfnr-wz">红包金额：<span class="xfnr-wz5">{$rl.award_money}</span></div>
  </div>
   {/volist}
</section>
<!--section3提现明细-->
<section style="display:none;" id="nash3">
 {volist name="WithdrawMsg" id="wm" }
 <div class="xfnr-bx">
 <div class="xfnr-wz">提现时间:<span class="xfnr-wz4">{$wm.payment_time}</span></div>
 <div class="xfnr-wz">提现金额：<span class="xfnr-wz5">{$wm.money}</span></div>
 <div class="xfnr-wz">提现状态：<span class="xfnr-wz4">{$wm.desc}</span></div>
</div>
   {/volist}


</section>
<script>
$(document).ready(function(){
	 $("#ti").click(function(){
	  $(".tixian1").fadeIn();
	  $(".tixian2").fadeIn(); 
	  $("#tixian").focus();
	 });
	 
	 $(".tixian4").click(function(){
	  $(".tixian1").fadeOut();
	  $(".tixian2").fadeOut(); 
	 });
	 
	
	      
	});
<!--按钮切换-->
function show(){
    if(document.getElementById("yao2")){
    document.getElementById("nash2").style.display="block";
    document.getElementById("nash1").style.display="none";
	document.getElementById("nash3").style.display="none";
    }
    } 
function hide(){
    if(document.getElementById("yao1")){
    document.getElementById("nash1").style.display="block";
    document.getElementById("nash2").style.display="none";
	document.getElementById("nash3").style.display="none";
    }
    } 
function showtx(){
    if(document.getElementById("yao3")){
    document.getElementById("nash3").style.display="block";
    document.getElementById("nash1").style.display="none";
	document.getElementById("nash2").style.display="none";
    }
    } 
</script>
  <script type="text/javascript">
		history.pushState(null, null, location.href);
		window.addEventListener('popstate', function(event) {
		    history.pushState(null, null, location.href );
		    //此处加入回退时你要执行的代码
		    wx.closeWindow();
		}); 
 </script>
</body>
</html>
